/*
 * Copyright © 2021 http://www.TestCopyright.com/ All rights reserved.
 */
package com.xjh;

import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.data.jpa.repository.config.EnableJpaRepositories;
import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
import org.springframework.security.oauth2.config.annotation.web.configuration.EnableResourceServer;

/**
 * Created with IntelliJ IDEA.
 *
 * @author： 徐建华
 * @date： 2021/11/28
 * @description：
 * @modifiedBy：
 * @version: 1.0
 */
@SpringBootApplication
//来标注一个主程序类，说明这是一个Spring Boot应用
@MapperScan(basePackages = {"com.xjh.mapper","com.xjh.jparepository"})
@ComponentScan(basePackages = {"com.xjh.config"})
@EnableJpaRepositories("com.xjh.jparepository")
// 引入springSecurity，不加注解，只是引入依赖也可以
@EnableWebSecurity
@EnableResourceServer
public class WebApplication {
    public static void main(String[] args) {
        SpringApplication application = new SpringApplication(WebApplication.class);
        application.run(args);
    }
}
